#ifndef DRLISTITEM_H
#define DRLISTITEM_H

#include <QWidget>
#include <QPixmap>
#include <QDateTime>

namespace Ui {
class DRListItem;
}

class DRListItem : public QWidget
{
    Q_OBJECT

public:
    explicit DRListItem(QWidget *parent = 0);
    explicit DRListItem(int index, QString text, QString time, bool alerm = false, QWidget *parent = 0);
    ~DRListItem();
    void setText(QString text);
    QString text();
    void setTime(QString time);
    QString time();
    void setAlerm(bool alerm);
    bool alerm();
    int index();
    void setText(int index);

signals:
    void onDelete(int index);

private slots:
    void deleteClicked();

private:
    Ui::DRListItem *ui;
    void enterEvent(QEvent * event);
    void leaveEvent(QEvent * event);

    bool _alerm;
    int  _index;
};

#endif // DRLISTITEM_H
